package com.systar.activity;

import java.io.IOException;
import java.util.Properties;

import com.systar.activity.monitor.ActivityManager;
import com.systar.activity.ui.ActivityDialog;

public class ActivityLauncher
{
	private ActivityLauncher()
	{
		// none
	}

	/**
	 * Launch the application.
	 * 
	 * @param args
	 *            the filename.
	 */
	public static void main(String args[])
	{
		// load properties
		Properties props = new Properties();
		try
		{
			props.load(ActivityLauncher.class.getResourceAsStream("activity.properties"));
		}
		catch (IOException e)
		{
			// ESCA-JAVA0267:
			System.err.println(e.getMessage());
			return;
		}

		// create monitor
		ActivityManager manager = new ActivityManager(props, false);

		// Create UI
		ActivityDialog dialog = new ActivityDialog(null, manager);

		dialog.setBlockOnOpen(true);
		dialog.open();
	}

}
